home *** CD-ROM | disk | FTP | other *** search
/ FishMarket 1.0 / FishMarket v1.0.iso / fishies / 351-375 / disk_352 / mg / rexx / man.mg < prev    next >
Text File  |  1992-05-06  |  502b  |  25 lines

  1. /* Rexx macro to load a "man page" into mg */
  2.  
  3. options results
  4.  
  5. /* Get the page name, and see if it exists */
  6. 'rexx-request "Manual entry: "'
  7. if rc ~= 0 then do
  8.     'rexx-display ""'
  9.     return
  10.     end
  11.  
  12. file = 'docs:'result
  13. if ~exists(file) then do
  14.     'rexx-display "No manual page for'  result'"'
  15.     exit
  16.     end
  17.  
  18. /* It does, so clear a buffer for it and read it in */
  19. manbuf = '"*Manual_Entry*"'
  20. 'switch-to-buffer-other-window' manbuf
  21. 'not-modified'
  22. 'kill-buffer' manbuf
  23. 'switch-to-buffer' manbuf
  24. 'insert-file' file
  25.